const mongoose = require('mongoose');
const { baseModel } = require('./baseModel');
const studentWorkSchema = new mongoose.Schema({
    //作业id
    workId:{
        type:mongoose.Schema.Types.ObjectId,
        ref:'HomeWork',
        required:true
    },
    //学生id
    studentId:{
        type:mongoose.Schema.Types.ObjectId,
        ref:'Student',
        required:true
    },
    //上传状态
    state:{
        type:Number,
        default:0 // 0 未上传 1 已上传
    },
    //文件id
    fileId:{
        type:String,
        default:''
    },
    ...baseModel
})

module.exports = studentWorkSchema